Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Misc tauri fixes #503

Closed
wants to merge 3 commits into from
Closed

Conversation

0rvar
Copy link

@0rvar 0rvar commented Nov 13, 2023

  • Add empty updater config in development (refused to build otherwise)
  • Switch to LogicalSize instead of PhysicalSize to support high-dpi screens like Macbooks
  • Implement hiding to tray when exiting window

There's some rustfmt in there as well.

I can split these changes up into separate PRs as needed, and if you wish I could get rid of the rustfmt diffs. Let me know.

Otherwise it fails to build at all
LogicalSize is what we want, to make the app work properly on retina displays
@0rvar 0rvar force-pushed the orvar/fix-tauri-window-sizing branch from 50e8864 to a686d12 Compare November 13, 2023 12:20
@@ -49,6 +54,9 @@ fn main() {

println!("Pomatez is ready");
}
RunEvent::ExitRequested { api, .. } => {
api.prevent_exit();
Copy link
Member

@sekwah41 sekwah41 Nov 13, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I thought I'd already implemented the closing to tray in the settings?

Or are you talking about the Mac's close to tray? If so, you'll need to add a check or a compiler flag to make sure it doesn't do this on Windows as that is not the expected behavior.

Ill be honest I've only lightly tested it on a very old mac so id just like to outline the current behavior vs expected.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How is this implemented for these other platforms on tauri? I cannot find any code that handles this for any platform

Copy link
Member

@sekwah41 sekwah41 Nov 13, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't believe they expect apps to handle it themselves, I tauri just provides a platform to make apps. The same as electron doesn't implement this behavior either.

@sekwah41
Copy link
Member

sekwah41 commented Nov 13, 2023

I was only testing with a really old MacBook though today I just got a new device with a high dpi screen

Screenshot 2023-11-13 at 19 18 00

Im going to pull the changes out into a separate commit for now before I take a look at the hiding window changes.

Hiding to tray already exists though I believe the term for what you may have changed is hiding to dock? Feel free to correct me.

@sekwah41
Copy link
Member

I believe these have been fixed by my changes already so I'm closing this for now.

@sekwah41 sekwah41 closed this Mar 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Closed/Done
Development

Successfully merging this pull request may close these issues.

2 participants